import axios from '../utils/request'

function getBlog(query) {
    return axios.get('/blog/list', { params: query })
}

function addBlog(body) {
    return axios.post('/blog/list', body)
}

function editBlog(body) {
    return axios.put('/blog/list', body)
}

function delBlog(id) {
    return axios.delete('/blog/list/' + id)
}

export default {
    getBlog,
    addBlog,
    editBlog,
    delBlog
}